<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>离线模式</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            text-align: center;
            padding: 50px 20px;
            background: #f5f5f5;
        }
        .container {
            background: white;
            padding: 40px;
            border-radius: 10px;
            box-shadow: 0 2px 10px rgba(0,0,0,0.1);
            max-width: 500px;
            margin: 0 auto;
        }
        h1 {
            color: #e74c3c;
        }
        button {
            background: #3498db;
            color: white;
            border: none;
            padding: 10px 20px;
            margin: 10px;
            border-radius: 5px;
            cursor: pointer;
        }
    </style>
</head>
<body>
<div class="container">
    <h1>🔌 离线模式</h1>
    <p>当前处于离线状态，部分功能可能无法使用。</p>
    <button onclick="checkConnection()">检查网络连接</button>
    <button onclick="retry()">重新尝试</button>
</div>

<script>
    function checkConnection() {
        if (typeof AndroidBridge !== 'undefined') {
            const isOnline = AndroidBridge.isOnline();
            alert(isOnline ? '网络已连接！' : '仍然处于离线状态');
        }
    }

    function retry() {
        if (typeof AndroidBridge !== 'undefined') {
            AndroidBridge.retry();
        }
    }
</script>
</body>
</html>